#ifndef __DLIGHT_BH1750_H__
#define __DLIGHT_BH1750_H__

/* Includes --------------------------------------------------------------------------------------*/

#ifdef __cplusplus
extern "C" {
#endif

/**
 * @brief BH1750 环境光传感器初始化
 *
 * @return int 0 on success; -1 on error.
 */
int setup_bh1750(void);

/**
 * @brief BH1750 测光
 *
 * @param[out] value 测光结果，lux 为档位
 * @return true 测光数值有效
 * @return false 测光失败
 */

bool loop_bh1750_scan(void);

double bh1750_get_lux(void);

#ifdef __cplusplus
}
#endif

#endif /* !__DLIGHT_BH1750_H__ */
